#include "eu2_demo.h";
#include <iostream>
#include <Windows.h>
int main(int argc, char* argv[])
{
    CameraAI::CameraHelper helper = CameraAI::CameraHelper();
    if (argc == 1)
    {
        std::cout << helper.EnumDevice() << std::endl;
    }
    if(argc == 2)
    {
        std::cout<< helper.GetDeviceSatus(argv[1]) << std::endl;
    }
    else if (argc == 3)
    {
        auto cmd = atoi(argv[2]);
        if(cmd < 8)
            std::cout << helper.SetDeviceSatus(argv[1], atoi(argv[2])) << std::endl;
        else
        {
            if((cmd & 0b1000) > 0)
                helper.SetDeviceSatus(argv[1], (cmd & 0b0111));
            auto mirror = cmd >> 4;
            if((mirror & 0b1000) > 0 )
                helper.SetMirror(argv[1], (mirror & 0b0111));
            auto language = cmd >> 8;
            if((language & 0b1000) > 0)
                helper.SetLanguage(argv[1], (language & 0b0111));
        }
        
    }
    helper.~helper();
    //std::cout << argc << std::endl;
	return 0;
}